package  
{
	import org.flixel.FlxRect;
	import org.flixel.FlxText;
	import org.flixel.FlxG;
	import Data.Color;
	
	public class Room extends FlxRect
	{
		public var name:String;
		public var displayText:FlxText;
		
		public function Room(X:Number, Y:Number, Width:Number, Height:Number, Name:String, textY:Number, Text:String, color:uint = Color.WhiteWOA) 
		{
			super(X, Y, Width, Height);
			
			setupText(textY, Text, color);
			
			name = Name;
		}
		
		public function setupText(Y:Number, Text:String, color:uint = Color.WhiteWOA):void
		{
			displayText = new FlxText(x, y + Y, width, Text);
			displayText.setFormat(null, 20, color, "center");
			displayText.visible = false;
		}
		
		public function Toggle(setTo:Boolean):void
		{
			displayText.visible = setTo;
		}
	}
}